1. Field of the Invention
The present invention relates to a three-dimensional image generation device, a three-dimensional image generation method, and an information storage medium, which are used for generating a three-dimensional image that a viewer can visually recognize in a stereoscopic manner.
2. Description of the Related Art
Studies have been conducted on a technology for realizing stereoscopic display through which a viewer can visually recognize an image in a stereoscopic manner. As one of the stereoscopic display techniques, there is a technology of generating two images showing the same single object viewed from different points of view, and displaying the images so that one of the images (right eye image) is visually recognized through the right eye of the viewer while the other image (left eye image) is visually recognized through the left eye, respectively (see, for example, U.S. Pat. No. 5,808,591). When this technology is used for displaying a scene within a virtual three-dimensional space, two cameras, that is, a right eye camera and a left eye camera, are set in the virtual three-dimensional space, and images showing the scene within the virtual three-dimensional space viewed from the respective cameras are generated. Specifically, in order to generate the right eye image and the left eye image for stereoscopic display, it is necessary to determine positions and directions (lines of sight) of the two cameras in the virtual three-dimensional space.
In general, those positions and directions of the two cameras are determined based on two parameters. Specifically, the parameters are a parameter indicating a distance between the two cameras (hereinafter, referred to as camera interval parameter i) and a parameter regarding an angle defined by the directions of the two cameras (convergence angle) (hereinafter, referred to as convergence angle parameter α). Based on those parameters, the positions and directions of the right eye camera and the left eye camera with respect to a reference camera position and a reference camera direction are determined. The reference camera defines a target area of a stereoscopic display, and the position, direction, and angle of view of the reference camera are used for specifying which area of the virtual three-dimensional space viewed from which direction is to be rendered.
FIG. 1 illustrates a relation between the above-mentioned two parameters and the positions and directions of the two cameras, and illustrates a view of the virtual three-dimensional space from above. The directions of the reference camera, the right eye camera, and the left eye camera are indicated by two-dot chain lines and the angles of view of the respective cameras are indicated by chain lines. In FIG. 1, a right eye camera position RP and a left eye camera position LP are determined so that the two cameras are spaced apart from each other by the distance i with a reference camera position CP set as the center therebetween. The right eye camera and the left eye camera are both disposed so as to be included in a horizontal plane and in a plane orthogonal to a reference camera direction CD. A right eye camera direction RD is determined as a direction inclined by an angle +α from the reference camera direction CD in the horizontal plane, and a left eye camera direction LD is determined as a direction inclined by an angle −α from the reference camera direction CD in the horizontal plane. That is, the angle α, corresponds to half an angle defined by the right eye camera direction RD and the left eye camera direction LD.
In this example, a virtual display screen (hereinafter, referred to as virtual screen Sv) exists in a plane orthogonal to the reference camera direction CD with an intersection of the two camera directions (point So of FIG. 1) set as the center thereof. The virtual screen Sv corresponds to a display screen of a stereoscopic display device for stereoscopic display in a real space. A relative depth of the virtual screen Sv to objects located in the virtual three-dimensional space when viewed from the reference camera is identical with a relative depth of the display screen of the stereoscopic display device to virtual positions of the objects displayed in a stereoscopic manner when viewed from the viewer. Specifically, an object O1 located behind the virtual screen Sv when viewed from the reference camera position CP is recognized by the viewer as being farther from the viewer than the display screen when displayed in a stereoscopic manner. On the other hand, an object O2 located in front of the virtual screen Sv (on the reference camera position CP side) is recognized by the viewer as being closer to the viewer than the display screen. A horizontal width of the virtual screen Sv is determined according to a horizontal angle of view θ of the reference camera, and the angles of view of the right eye camera and the left eye camera are determined so that the virtual screen Sv is included in their fields of view.